package com.acc.mobileappr.entities;

import javax.persistence.Basic;
import javax.persistence.Entity;
import javax.persistence.Id;
import java.sql.Date;

/**
 * Created by IntelliJ IDEA.
 * User: user
 * Date: Apr 20, 2011
 * Time: 10:54:47 AM
 * To change this template use File | Settings | File Templates.
 */
@javax.persistence.IdClass(com.acc.mobileappr.entities.MstMApprStructureEntityPK.class)
@javax.persistence.Table(name = "MST_M_APPR_STRUCTURE", schema = "ACC_BBMX")
@Entity
public class MstMApprStructureEntity {
    private String docId;

    @javax.persistence.Column(name = "DOC_ID")
    @Id
    public String getDocId() {
        return docId;
    }

    public void setDocId(String docId) {
        this.docId = docId;
    }

    private String screenName;

    @javax.persistence.Column(name = "SCREEN_NAME")
    @Id
    public String getScreenName() {
        return screenName;
    }

    public void setScreenName(String screenName) {
        this.screenName = screenName;
    }

    private String contentId;

    @javax.persistence.Column(name = "CONTENT_ID")
    @Id
    public String getContentId() {
        return contentId;
    }

    public void setContentId(String contentId) {
        this.contentId = contentId;
    }

    private String version;

    @javax.persistence.Column(name = "VERSION")
    @Id
    public String getVersion() {
        return version;
    }

    public void setVersion(String version) {
        this.version = version;
    }

    private String indexOnScreen;

    @javax.persistence.Column(name = "INDEX_ON_SCREEN")
    @Id
    public String getIndexOnScreen() {
        return indexOnScreen;
    }

    public void setIndexOnScreen(String indexOnScreen) {
        this.indexOnScreen = indexOnScreen;
    }

    private String structureDesc;

    @javax.persistence.Column(name = "STRUCTURE_DESC")
    @Basic
    public String getStructureDesc() {
        return structureDesc;
    }

    public void setStructureDesc(String structureDesc) {
        this.structureDesc = structureDesc;
    }

    private String structure;

    @javax.persistence.Column(name = "STRUCTURE")
    @Basic
    public String getStructure() {
        return structure;
    }

    public void setStructure(String structure) {
        this.structure = structure;
    }

    private Date createdDate;

    @javax.persistence.Column(name = "CREATED_DATE")
    @Basic
    public Date getCreatedDate() {
        return createdDate;
    }

    public void setCreatedDate(Date createdDate) {
        this.createdDate = createdDate;
    }

    private String createdBy;

    @javax.persistence.Column(name = "CREATED_BY")
    @Basic
    public String getCreatedBy() {
        return createdBy;
    }

    public void setCreatedBy(String createdBy) {
        this.createdBy = createdBy;
    }

    private String queryStatement;

    @javax.persistence.Column(name = "QUERY_STATEMENT")
    @Basic
    public String getQueryStatement() {
        return queryStatement;
    }

    public void setQueryStatement(String queryStatement) {
        this.queryStatement = queryStatement;
    }

    private String character;

    @javax.persistence.Column(name = "CHARACTER")
    @Basic
    public String getCharacter() {
        return character;
    }

    public void setCharacter(String character) {
        this.character = character;
    }

    private String bucket;

    @javax.persistence.Column(name = "BUCKET")
    @Basic
    public String getBucket() {
        return bucket;
    }

    public void setBucket(String bucket) {
        this.bucket = bucket;
    }

    private String subCategory;

    @javax.persistence.Column(name = "SUB_CATEGORY")
    @Basic
    public String getSubCategory() {
        return subCategory;
    }

    public void setSubCategory(String subCategory) {
        this.subCategory = subCategory;
    }

    private String subCategoryIndex;

    @javax.persistence.Column(name = "SUB_CATEGORY_INDEX")
    @Basic
    public String getSubCategoryIndex() {
        return subCategoryIndex;
    }

    public void setSubCategoryIndex(String subCategoryIndex) {
        this.subCategoryIndex = subCategoryIndex;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        MstMApprStructureEntity that = (MstMApprStructureEntity) o;

        if (bucket != null ? !bucket.equals(that.bucket) : that.bucket != null) return false;
        if (character != null ? !character.equals(that.character) : that.character != null) return false;
        if (contentId != null ? !contentId.equals(that.contentId) : that.contentId != null) return false;
        if (createdBy != null ? !createdBy.equals(that.createdBy) : that.createdBy != null) return false;
        if (createdDate != null ? !createdDate.equals(that.createdDate) : that.createdDate != null) return false;
        if (docId != null ? !docId.equals(that.docId) : that.docId != null) return false;
        if (indexOnScreen != null ? !indexOnScreen.equals(that.indexOnScreen) : that.indexOnScreen != null)
            return false;
        if (queryStatement != null ? !queryStatement.equals(that.queryStatement) : that.queryStatement != null)
            return false;
        if (screenName != null ? !screenName.equals(that.screenName) : that.screenName != null) return false;
        if (structure != null ? !structure.equals(that.structure) : that.structure != null) return false;
        if (structureDesc != null ? !structureDesc.equals(that.structureDesc) : that.structureDesc != null)
            return false;
        if (subCategory != null ? !subCategory.equals(that.subCategory) : that.subCategory != null) return false;
        if (subCategoryIndex != null ? !subCategoryIndex.equals(that.subCategoryIndex) : that.subCategoryIndex != null)
            return false;
        if (version != null ? !version.equals(that.version) : that.version != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = docId != null ? docId.hashCode() : 0;
        result = 31 * result + (screenName != null ? screenName.hashCode() : 0);
        result = 31 * result + (contentId != null ? contentId.hashCode() : 0);
        result = 31 * result + (version != null ? version.hashCode() : 0);
        result = 31 * result + (indexOnScreen != null ? indexOnScreen.hashCode() : 0);
        result = 31 * result + (structureDesc != null ? structureDesc.hashCode() : 0);
        result = 31 * result + (structure != null ? structure.hashCode() : 0);
        result = 31 * result + (createdDate != null ? createdDate.hashCode() : 0);
        result = 31 * result + (createdBy != null ? createdBy.hashCode() : 0);
        result = 31 * result + (queryStatement != null ? queryStatement.hashCode() : 0);
        result = 31 * result + (character != null ? character.hashCode() : 0);
        result = 31 * result + (bucket != null ? bucket.hashCode() : 0);
        result = 31 * result + (subCategory != null ? subCategory.hashCode() : 0);
        result = 31 * result + (subCategoryIndex != null ? subCategoryIndex.hashCode() : 0);
        return result;
    }
}
